<?php if (defined("YTDJ") or die()); 

/**
 * YouTubeFeedDetail
 * @deprecated 
 *
 */
class YouTubeFeedDetail extends FeedHelper {
	
	var $id;
	
	var $title;
	
	var $duration;
	var $rating;
	var $thumbnail;
	
	function __construct($id) {
		$url = "http://gdata.youtube.com/feeds/api/videos/$id";
		$xml = FeedHelper::loadFeed($url);
		
		
		
		$this->id = $id;
		$this->title = $this->getXPathValue($xml, "//default:title");
		$this->duration = $this->getXPathAttr($xml, "//media:group/yt:duration", "seconds"); 
		$this->rating = $this->getXPathAttr($xml, "//gd:rating", "average");
		$this->thumbnail = $this->getXPathAttr($xml, "//media:thumbnail", "url");		
	}
	
}

?>